package com.struct.graph.login
{
	import com.component.Component;
	import com.component.button.Button;
	import com.utils.Utils;
	
	import flash.text.TextField;
	
	public class LoginFrame extends Component
	{
		public var txtUserName:TextField;
		public var txtPassWord:TextField;
		public var btnLogin:Button;
		
		public function LoginFrame()
		{
			super();
			createChildren();
		}
		private function createChildren():void{
			Utils.createTextField(this, 0, 0, "账号:");
			Utils.createTextField(this, 0, 25, "密码:");
			txtUserName = Utils.creatBorderTextField(this, 60, 0, 120);
			txtPassWord = Utils.creatBorderTextField(this, 60, 25, 120);
			txtUserName.text = "Sacu";
			txtPassWord.text = "1234";
			
			btnLogin = new Button("登录");
			btnLogin.x = (width - btnLogin.width) / 2;
			btnLogin.y = 65;
			addChild(btnLogin);
			
			x = (SSA.application.width - width) / 2;
			y = (SSA.application.height - height) / 2;
		}
	}
}